package track
{
	import utils.Vector2D;

	/**
	 * 1	对角线型
	 **/
	public class TrackC2C extends TrackProto
	{
		private static var _instance:TrackC2C;
		public function TrackC2C()
		{
			super();
		}
		
		public static function getInstance():TrackC2C{
			return _instance ||= new TrackC2C();
		}
		
		override public function make(subTypeId:uint):Array{
            var startX:int;
            var startY:int;
            var endX:int;
            var endY:int;
		    switch(subTypeId){
		        case 0://右下到左上
		            startX = Const.WIDTH + 100;
                    startY = Const.HEIGHT + 100;
                    endX = -100;
                    endY = -100;
		            break;
		        case 1://左上到右下
		            startX = -100;
                    startY = -100;
                    endX = Const.WIDTH + 100;
                    endY = Const.HEIGHT + 100;
		            break;
		        case 2://左下到右上
		            startX = -100;
                    startY = Const.HEIGHT + 100;
                    endX = Const.WIDTH + 100;
                    endY = -100;
		            break;
		        case 3://右上到左下
		            startX = Const.WIDTH + 100;
                    startY = -100;
                    endX = -100;
                    endY = Const.HEIGHT + 100;
		            break;
		    }
            pathArr.push(new Vector2D(startX, startY));
            pathArr.push(new Vector2D(endX, endY));
			return pathArr;
		    
		}
	}
}
